package com.pro.service;

import com.pro.entity.UserCoupon;
import org.apache.ibatis.annotations.Delete;

import java.util.List;

/**
 * @ClassName: UserCouponService
 * @Author: 笑笑
 * @DATE: 2021/11/18
 * @TIME: 下午 08:47
 */
public interface UserCouponService {

    //查询所有优惠券信息--表
    List<UserCoupon> getAllTable(UserCoupon userCoupon);

    //根据id查看优惠券
    UserCoupon getById(Integer couponId) throws Exception;

    //根据id删除优惠券
    @Delete("DELETE FROM js_user_coupon WHERE coupon_id = couponId")
    Boolean deleteUserCoupon(Integer couponId) throws Exception;

    //添加优惠券
    Boolean addUserCoupon(UserCoupon userCoupon);

    //根据id修改优惠券
    Boolean updateUserCoupon(UserCoupon userCoupon) throws Exception;
}
